<div style="position: fixed; background: #ffffff; z-index: 999999999; height: calc(100% - 264px); top: 158px; right: 0px; border: 1px solid #e6e6e6; padding: 10px; width: 400px; overflow: hidden; transition: all 0.6s; display: none;" id="bjd_select_goods">
	<div style="line-height: 30px; "><h2>选择报价商品</h2></div>
	<div class="select-data-box" style="line-height: 24px; height: calc(100% - 110px);  overflow-y: auto; background: #fafafa; padding: 10px; margin: 10px 0px;">
		
	</div>
	<div style="position: absolute; width: 400px; right: 10px; bottom: 10px; display: flex; justify-content: space-between;z-index: 9999999999; background: #ffffff;">
		<a type="button" data-title="取消导出" class="layui-btn layui-btn-primary layui-btn" lay-event="closeCgGoods">取消导出</a>
		<a type="button" data-title="导出报价单" data-url="/supplier/goods/exportcggoods.html" class="layui-btn layui-btn-normal layui-btn" lay-event="exportCgGoods">确定导出</a>
	</div>
</div> 
<div class="search-box">
	<form class="search_form layui-form" lay-filter="goods_jun_search_form">
		<div class="layui-inline">
			<label class="layui-form-label">分类</label>
			<div class="layui-input-inline">
				<select name="category_sign1" id="category_search1" lay-filter="list_category_search1" lay-search>
				</select>
			</div>
			<div class="layui-input-inline">
				<select name="category_sign2" id="category_search2" lay-filter="list_category_search2" lay-search>
				</select>
			</div>
			<div class="layui-input-inline">
				<select name="category_sign3" id="category_search3" lay-filter="list_category_search3" lay-search>
				</select>
			</div>
		</div>
		<div class="layui-inline">
			<label class="layui-form-label">名称</label>
			<div class="layui-input-inline">
				<input type="text" name="goods_name" autocomplete="off" class="layui-input">
			</div>
		</div>
		<div class="layui-inline">
			<label class="layui-form-label">编号</label>
			<div class="layui-input-inline">
				<input type="text" name="goods_sku" autocomplete="off" class="layui-input">
			</div>
		</div>
		<div class="layui-inline">
			<label class="layui-form-label">军网编号</label>
			<div class="layui-input-inline">
				<input type="text" name="jun_id" autocomplete="off" class="layui-input">
			</div>
		</div>
		<div class="layui-inline">
			<label class="layui-form-label">型号</label>
			<div class="layui-input-inline">
				<input type="text" name="goods_model" autocomplete="off" class="layui-input">
			</div>
		</div>
		<div class="layui-inline">
			<label class="layui-form-label">限价</label>
			<div class="layui-input-inline">
				<input type="text" name="min_price" autocomplete="off" class="layui-input" placeholder="最低限价">
			</div>
			<div class="layui-input-inline">
				<input type="text" name="max_price" autocomplete="off" class="layui-input" placeholder="最高限价">
			</div>
		</div>
		<div class="layui-inline">
			<label class="layui-form-label">发布时间</label>
			<div class="layui-input-inline">
				<input type="text" name="goods_form_create_time_start" autocomplete="off" class="layui-input" placeholder="开始日期">
			</div>
			<div class="layui-input-inline">
				<input type="text" name="goods_form_create_time_end" autocomplete="off" class="layui-input" placeholder="结束日期">
			</div>
		</div>
		<div class="layui-inline">
			<div class="layui-input-inline">
				<button type="button" id="jun_search_btn"
					class="layui-btn layui-btn-normal layui-btn-sm layui-bg-red">搜 索</button>
			</div>
		</div>
		<div class="pack-up"></div>
	</form>
</div>
<div style="padding: 30px; display: none;" id="baojia_jun_box">
		<div class="layui-form-item">
			<label class="layui-form-label">报价金额</label>
			<div class="layui-input-inline">
				<input type="text" name="baojia" id="baojia" autocomplete="off" class="layui-input" placeholder="报价金额">
			</div>
		</div>
		<div class="layui-form-item">
			<label class="layui-form-label">库存</label>
			<div class="layui-input-inline">
				<input type="text" name="kucun" id="kucun" autocomplete="off" value="4" class="layui-input" placeholder="4">
			</div>
		</div>
	</div>
<table class="layui-hide" id="goods_jun_list" lay-filter="goods_jun_list"></table>
<script>
	
	var goods_jun_list_url = "{:url('Goods/ajaxList',array('pre_info'=>'jun'))}",
		goods_delete_url = "{:url('Goods/ajaxDelete')}",
		goods_up_url = "{:url('Goods/ajaxUp')}",
		goods_down_url = "{:url('Goods/ajaxDown')}",
		goods_one_url = "{:url('Goods/ajaxOneData')}",
		goods_save_url = "{:url('Goods/saveData')}",
		goods_copy_url = "{:url('Goods/copy')}",
		goods_collect_url = "{:url('Goods/collect')}",
		category_select_uri = "{:url('Category/ajaxCategory')}",
		brand_select_uri = "{:url('Brand/ajaxList')}",
		goods_jun_cols = {$cols},
		goods_select_site_id = '',
		goods_upload_url = "{:url('goods/upload')}",
		goods_jun_comm = "{:url('goods/implodeGoodsComm')}",
		goods_transfer_url = "{:url('goods/transfer')}",
		site_data_url = "{:url('goods/siteData')}",
		goods_export_url = "{:url('goods/exportGoods')}",
		goods_export_cg_url = "{:url('goods/exportCgGoods')}",
		goods_delete_url = "{:url('goods/ajaxDelete')}",
		audit_log_url = "{:url('audit/auditLog')}",
		site_id = "{$site_id}",
		baojia_url = "{:url('goods/saveBaojia')}",
		chk_today_baojia_url = "{:url('goods/chkTodayBaojia')}",
		site_name = '{$get_site.site_name}';

	if($('form[lay-filter="goods_search_form"]').find('select[name="site_id"]').length == 1) {
		goods_select_site_id = $('form[lay-filter="goods_search_form"]').find('select[name="site_id"]').val();
	}
	$.getScript('/static/js/goods/jun.js');
</script>
<script type="text/html" id="goodsjunToolbar">
	<div class="layui-btn-container">
		<a type="button" data-title="生成报价单" class="layui-btn layui-btn-normal layui-btn-sm" lay-event="setExportCgGoods"><i class="layui-icon layui-icon-spread-left"></i>生成报价单</a>
	{if condition="menuAuth('er_goods_baojia')"}
		<a type="button" data-title="申请报价" class="layui-btn layui-btn-normal layui-btn-sm" lay-event="createExportCgGoods"><i class="layui-icon layui-icon-spread-left"></i>申请报价</a>
		{/if}
		<a type="button" class="layui-btn layui-btn-normal layui-btn-sm" href="http://tailongjipc.dixintong.com/goods_list.html" target="_blank">产品网站</a>
	</div>
</script>
<script type="text/html" id="goods_jun_tool">
	<div class="layui-btn-group">
		<a class="layui-btn layui-btn-normal layui-btn-xs tap-nav" lay-event="edit" data-id="edit_goods_{{ d.goods_sku}}" data-url="{:url('goods/tplFormJun')}?goods_sku={{ d.goods_sku}}" data-title="商品详情"><i class="layui-icon layui-icon-file-b"></i></a>
		<a class="layui-btn layui-btn-danger layui-btn-xs hide-update" lay-event="update"><i class="layui-icon layui-icon-up"></i></a>
	</div>
</script>
<script type="text/html" id="goods_pictureTpl">
	{{# if(d.goods_picture){ return '<a data-title="<img src='+d.goods_picture.save_path+' width=182 />" class="layui-btn layui-btn-sm" style="background-color:#fff;"><img src="'+d.goods_picture.save_path+'" /></a>'; } }}
</script>
<script type="text/html" id="is_realTpl">
	{{# if(d.is_real == 1 || d.is_real == true){ }}
	<input type="checkbox" name="is_real" lay-skin="switch" checked lay-text="是|否" disabled=""> {{# } else { }}
	<input type="checkbox" name="is_real" lay-skin="switch" lay-text="是|否" disabled=""> {{# } }}
</script>
<script type="text/html" id="is_shoppingTpl">
	{{# if(d.is_shopping == 1 || d.is_shopping == true){ }}
	<input type="checkbox" name="is_shopping" lay-skin="switch" checked lay-text="是|否" disabled=""> {{# } else { }}
	<input type="checkbox" name="is_shopping" lay-skin="switch" lay-text="是|否" disabled=""> {{# } }}
</script>
<script type="text/html" id="goods_nameTpl">
	{{# if(d.view_stock == 4){}}
	<font color="#ff0000"><strong>{{d.goods_name}}</strong></font>
	{{# } else {}}
	{{d.goods_name}}
	{{# }}}
</script>
<script type="text/html" id="category_nameTpl">
	{{# if(d.view_stock == 4){}}
	<font color="#ff0000"><strong>{{d.category_name}}</strong></font>
	{{# } else {}}
	{{d.category_name}}
	{{# }}}
</script>
<script type="text/html" id="jun_brand_nameTpl">
	{{# if(d.view_stock == 4){}}
	<font color="#ff0000"><strong>{{d.jun_brand_name}}</strong></font>
	{{# } else {}}
	{{d.jun_brand_name}}
	{{# }}}
</script>
<script type="text/html" id="beizhuTpl">
	{{# if(d.view_stock == 4){}}
	<font color="#ff0000"><strong>{{d.beizhu}}</strong></font>
	{{# } else {}}
	{{d.beizhu}}
	{{# }}}
</script>
<script type="text/html" id="jun_idTpl">
	{{# if(d.view_stock == 4){}}
	<font color="#ff0000"><strong>{{d.jun_id}}</strong></font>
	{{# } else {}}
	{{d.jun_id}}
	{{# }}}
</script>
<script type="text/html" id="zuidijiaTpl">
	{{# if(d.view_stock == 4){}}
	<font color="#ff0000"><strong>{{d.zuidijia}}</strong></font>
	{{# } else {}}
	{{d.zuidijia}}
	{{# }}}
</script>
<script type="text/html" id="jun_zuidijiaTpl">
	{{# if(d.view_stock == 4){}}
	<font color="#ff0000"><strong>{{d.jun_zuidijia}}</strong></font>
	{{# } else {}}
	{{d.jun_zuidijia}}
	{{# }}}
</script>
<script type="text/html" id="sale_priceTpl">
	{{# if(d.view_stock == 4){}}
	<font color="#ff0000"><strong>{{d.sale_price}}</strong></font>
	{{# } else {}}
	{{d.sale_price}}
	{{# }}}
</script>
<script type="text/html" id="api_priceTpl">
	{{# if(d.view_stock == 4){}}
	<font color="#ff0000"><strong>{{d.api_price}}</strong></font>
	{{# } else {}}
	{{d.api_price}}
	{{# }}}
</script>
<script type="text/html" id="caigoujiaTpl">
	{{# if(d.view_stock == 4){}}
	<font color="#ff0000"><strong>{{d.caigoujia}}</strong></font>
	{{# } else {}}
	{{d.caigoujia}}
	{{# }}}
</script>
<script type="text/html" id="chengbenjiaTpl">
	{{# if(d.view_stock == 4){}}
	<font color="#ff0000"><strong>{{d.chengbenjia}}</strong></font>
	{{# } else {}}
	{{d.chengbenjia}}
	{{# }}}
</script>
<script type="text/html" id="goods_skuTpl">
	{{# if(d.view_stock == 4){}}
	<font color="#ff0000"><strong>{{d.goods_sku}}</strong></font>
	{{# } else {}}
	{{d.goods_sku}}
	{{# }}}
</script>
<script type="text/html" id="create_timeTpl">
	{{# if(d.view_stock == 4){}}
	<font color="#ff0000"><strong>{{d.create_time}}</strong></font>
	{{# } else {}}
	{{d.create_time}}
	{{# }}}
</script>
<script type="text/html" id="is_installTpl">
	{{# if(d.is_install == 1 || d.is_install == true){}}
	<div class="layui-anim circle layui-bg-blue" data-title="需要">
		<i class="layui-icon layui-icon-radio"></i>
	</div>
	{{# } else {}}
	<div class="layui-anim circle layui-bg-red" data-title="不需要">
		<i class="layui-icon layui-icon-radio"></i>
	</div>
	{{# }}}
</script>
<script type="text/html" id="sale_stateTpl">
	{{# if(d.sale_state == 1 || d.sale_state == true){}}
	<div class="layui-anim circle layui-bg-blue" data-title="在售">
		<i class="layui-icon layui-icon-radio"></i>
	</div>
	{{# } else {}}
	<div class="layui-anim circle layui-bg-red" data-title="下架">
		<i class="layui-icon layui-icon-radio"></i>
	</div>
	{{# }}}
</script>
<script type="text/html" id="audit_stateTpl">
	{{# if(d.audit_state == 1){}}
	<div class="layui-anim circle layui-bg-blue" data-title="通过">
		<i class="layui-icon layui-icon-radio"></i>
	</div>
	{{# } else if(d.audit_state == 0){ }}
	<div class="layui-anim circle layui-bg-orange" data-title="等待">
		<i class="layui-icon layui-icon-radio"></i>
	</div>
	{{# } else {}}
	<div class="layui-anim circle layui-bg-red" data-title="驳回：{{d.audit_remark?d.audit_remark:'无'}}">
		<i class="layui-icon layui-icon-radio"></i>
	</div>
	{{# }}}
</script>
